//
//  RetweetedCell.swift
//  XDweibo
//
//  Created by HanXingda on 15/7/4.
//  Copyright © 2015年 韩兴达. All rights reserved.
//

import UIKit
import FFAutoLayout
class RetweetedCell: StatusCell {

    override init(style: UITableViewCellStyle, reuseIdentifier: String?) {
        super.init(style: style, reuseIdentifier: reuseIdentifier)
       
        
        retweetLabel = UILabel(color: UIColor.darkGrayColor(), fontSize: 14, mutiLines: true)
        retweetLabel?.preferredMaxLayoutWidth = UIScreen.mainScreen().bounds.width - 16
        
        
        insertSubview(retweetLabel!, atIndex: 0)
        insertSubview(retButton, atIndex: 0)
        
       
        
        //设置布局
        retButton.ff_AlignVertical(ff_AlignType.BottomLeft, referView: contentLabel, size: nil, offset: CGPoint(x: -12, y: 12))
        retButton.ff_AlignVertical(ff_AlignType.TopRight, referView: footerView, size: nil)
        retweetLabel?.ff_AlignInner(ff_AlignType.TopLeft, referView: retButton, size: nil, offset: CGPoint(x: 12, y: 12))
        // 配图视图
       recordPictureViewCons( pictureView.ff_AlignVertical(ff_AlignType.BottomLeft, referView: retweetLabel!, size: CGSize(width: 290, height: 90), offset: CGPoint(x: 0, y: 12)))
        
    }

    required init(coder aDecoder: NSCoder) {
        fatalError("init(coder:) has not been implemented")
    }
    
    //懒加载
    
    lazy var retButton :UIButton = {
        
        let btn = UIButton()
        btn.backgroundColor = UIColor(white: 0.9, alpha: 1.0)
        return btn
    }()

}

